#include "CdiLightingBase.h"

CdiLightingBase::CdiLightingBase(LPDIRECT3DDEVICE9 pDevice )
  : CdiRenderBase( pDevice )
{
  Setup();
}

CdiLightingBase::CdiLightingBase( LPDIRECT3DDEVICE9 pDevice, D3DLIGHT9& light ) 
: CdiRenderBase( pDevice ), 
  m_light( light )
{
  Setup();
}

void CdiLightingBase::Setup()
{
  ZeroMemory( (void*)&m_light, sizeof( D3DLIGHT9 ) );
  SetEnabled( FALSE );
}

CdiLightingBase::~CdiLightingBase(void)
{
}

// Set the lighing Position
void CdiLightingBase::SetLighingPosition(D3DXVECTOR3& Position)
{
  m_light.Position = Position;
}

// Set the Lighting Direction
void CdiLightingBase::SetLightDirection(D3DXVECTOR3& Direction)
{
  m_light.Direction = Direction;
}
